package myUtil;

public class productCheck {
    public static boolean checkCode(String code) {
        if (code == null) {
            return false;
        }
        if (code.length()!=6)
            return false;
        return true;
    }

    public static boolean checkS(String s) {
        if (s == "") {
           return false;
        }
        else {
            return true;
        }
    }

    public static boolean checkBatch(String batch) {
        if (batch == null) {
            return false;
        }
        String pattern = "\\d+";
        if (!batch.matches(pattern)){
            return false;
        }else {
            return true;
        }
    }
}
